#ifndef _MT5_UICOMBO_H_
#define _MT5_UICOMBO_H_


#include "ui/ui_sprite.h"
#include "ui/ui_number.h"


class MATSpritePopupBase
{
public:
	MATSpritePopupBase();

	enum		COMBO_UI_STATE
	{
		UI_STATE_NONE,
		UI_STATE_START,
		UI_STATE_BIGGER,
		UI_STATE_RESMALLER,
		UI_STATE_STILL,
		UI_STATE_BIGGERAGAIN,
		UI_STATE_DISAPPEAR,

		UI_STATE_C,
	};


	
	void							Render();
	void							Tick(float dt);
	virtual void					OnShow() {};
	float							GetShowingTime()const;

protected:

	void							Show( float Delay, float ShowTime);
	ui::UISprite*					m_pSprite;
	math::Vec2						m_Size;

	float							m_Scale;
	float							m_Delay;


	float							m_ScaleExtra;
	float							m_Duration;
	COMBO_UI_STATE					m_UIState;	
};

class MATLevelCompletePopup : public MATSpritePopupBase
{
public:

	enum STATE_LEVEL
	{
		STATE_FAIL,
		STATE_COMPLETE,
		STATE_C,
	};

	MATLevelCompletePopup();

	void							Show(STATE_LEVEL State, float Delay, float ShowTime  = 1.0f);
	virtual void					OnShow();
	

protected:
	ui::UISprite					m_Sprite[STATE_C];
	

};


class MATUICombo : public MATSpritePopupBase
{
public:

	MATUICombo();
	
	void							Show(int Combo, float Delay, float ShowTime  = 1.0f);
	

protected:

	ui::UISprite					m_SpriteCombo[3];
	


};

#endif